package com.nft.service.school.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("user_books")
@ApiModel(value="UserBookEntity对象", description="用户图书收藏信息")
public class UserBookEntity implements Serializable {
    private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "图书收藏主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "图书信息id")
    private Long taskId;

    @ApiModelProperty(value = "图书信息标题")
    private String title;

    @ApiModelProperty(value = "收藏用户id")
    private Long userId;

    @ApiModelProperty(value = "收藏日期")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date createTime;
}
